<?php
/**
 * User: Do
 * Date: 7/2/14
 * Time: 10:51 AM
 */
class Database extends PDO {
    public function __construct() {
        try{
            parent::__construct("mysql:host=".DB_HOST.";dbname=".DB_NAME, DB_USER, DB_PASS, array(PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES utf8"));
        }
        catch(Exception $e){
            echo 'Database connection error!';
            exit;
        }
    }
}

?>
